/// GLSLShader.h
/// Matthew DiBernardo (Cryptex)
/// 07.28.09
///
/// Defines the GLSLShader class, a derivative of Shader designed to
/// implement the functionality required by a Shader using opengl's
/// GLSL language.

#ifndef _GLSLSHADER_H_
#define _GLSLSHADER_H_

#include "Shader.h"
#include "glee.h"	
#include <gl\gl.h>
#include <gl\glu.h>

#include <vector>

class GLSLShader : public Shader
{
private:
	std::vector<unsigned int> m_shaderID;
	
	GLhandleARB _LoadShaderPair(const char *szVertexProg, const char *szFragmentProg);
	bool bLoadShaderFile(const char *szFile, GLhandleARB shader);

public:
	~GLSLShader() {}

	//void SetShaderID(unsigned int shaderID) { m_shaderID = shaderID; }
	//unsigned int GetShaderID(void) { return m_shaderID; }

	void LoadNextPass(std::string vertexProg, std::string fragmentProg);

	void BindShader(void) { glUseProgram(m_shaderID[0]); }	
	void UnbindShader(void) { glUseProgram(NULL); }
	bool BindPass(unsigned int _pass);
};

#endif